home *** CD-ROM | disk | FTP | other *** search
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- CLPMK20.EXE
-
- a
-
- C L I P P E R M A K E U T I L I T Y
-
- Version 2.0
-
- Copyright (c) 1989 by Bill Tansill: ALL RIGHTS RESERVED
-
-
-
-
-
-
- This file describes the utility program CLPMK20.EXE, version 2.0
- created by Bill Tansill on April 20,1989.
-
- This utility is distributed on an "AS-IS" basis. The author
- may not be held liable for any special, consequential,
- incidental or other damages or loss of income. No warrenty
- of merchantability or fitness for a particular use is made,
- either express or implied.
-
- CLPMK20 is the copyrighted property of Bill Tansill. You are
- granted a limited license to use CLPMK20, and to copy and
- distribute it, provided that you agree to the following terms:
-
- 1) No fee may be charged for such copying and distribution.
- 2) CLPMK20 may be distributed ONLY in its original, unmodified
- form.
- 3) This documentation file must accompany CLPMK20.
- 4) This documentation file may not be altered.
-
- Any voluntary contributions for the use of this program will
- be appreciated, and should be sent to:
-
- Bill Tansill
- P.O. Box 3196
- Falls Church, Va. 22043
-
- A contribution of $15.00 is suggested.
-
- You may NOT use CLPMK20 in a Commercial or Governmental
- environment without making a contribution. An invoice is
- provided at the end of this document for your convenience.
-
-
-
-
-
- How to use CLPMK20
-
- The CLPMK20 syntax is very simple: type "CLPMK20" and any valid
- CLIPPER switches (-m -l -q etc.) from the DOS command line.
- Be sure to separate each switch with a space.
-
- CLPMK20 will scan your subdirectory, and will call Clipper
- to compile any .PRG files with a later time/date
- stamp than the corresponding .OBJ file. In the case of .CLP
- files, each program listed in the .CLP file is tested against
- the time/date stamp of the .OBJ file created when the .CLP
- file was originally compiled. If any programs whose names
- appear in the .CLP file (or the .CLP file itself) have a later
- time/date stamp, the contents of the .CLP file are recompiled.
-
- When Clipper is run from within CLPMK20, no error messages will
- appear on the screen. Error messages, should there be any,
- are redirected to a file named "CLP.TXT". If CLPMK20 signals
- that a compile-time error has occurred, use your editor to
- read the "CLP.TXT" file. This file will contain all CLIPPER
- generated error listings.
-
- Some assumptions apply. First, CLPMK20 assumes that the
- CLIPPER directory is in your PATH list. The second
- assumption is that you are calling CLPMK20 from the directory
- containing the files that you wish to compile. Finally,
- CLPMK20.EXE must be in a directory which is accessible from
- your PATH statement so that DOS can find it.
-
- Error Codes
-
- The DOS ERRORLEVEL is used to indicate errors detected by
- CLPMK20. The meaning of the error codes is as follows:
-
- ERRORLEVEL == 1 Indicates that there are no files which need
- to be compiled.
-
- ERRORLEVEL == 2 Indicates that no source files were found.
-
- ERRORLEVEL == 3 Indicates that one or more errors occurred
- during compilation.
-
- ERRORLEVEL == 4 Indicates that the arguments in the CLIPPER
- argument list were run together (-s-q) and need to be
- respecified (-s -q).
-
- ERRORLEVEL == 5 Indicates that there were one or more
- unrecognized arguments specified (-z).
-
- ERRORLEVEL == 6 Indicates that there were one or more
- program names listed in a .CLP file that were not present in
- the directory when it was scanned.
-
-
-
-
-
- ERRORLEVEL == 7 Indicates that a program name was found in
- two separate .CLP files. This will lead to duplicate symbol
- errors, and possibly flakey operation of your CLIPPER program.
-
-
-
-
- CLPMK20 Limits
-
- Except for generating error codes 4 and 5, CLPMK20 performs NO
- ERROR CHECKING. If you use CLPMK20 -oC:\FOO, CLIPPER will fail
- if the subdirectory FOO does not exist, but CLPMK20 will not
- warn you in advance. This was a conscious decision. Since
- CLIPPER provides error checking of its command line arguments,
- I felt that error checking on my part was redundant.
-
- CLPMK20 will only COMPILE files. It does NOT call the linker.
- It is best used in a batch file environment, where the batch
- file will call PLINK (or the linker of your choice if all files
- were successfully compiled. See example 1 for details.
-
- Example 1 && Suggested batch file configuration
-
- echo off
- cls
- CLPMK20 %1 %2 %3 %4 %5 %6 %7
- if ERRORLEVEL == 7 goto DUPE_FL
- if ERRORLEVEL == 6 goto MISSING_FL
- if ERRORLEVEL == 5 goto WRONG_ARGS
- if ERRORLEVEL == 4 goto BAD_ARGS
- if ERRORLEVEL == 3 goto BAD_FILES
- if ERRORLEVEL == 2 goto NO_SOURCE
- if ERRORLEVEL == 1 goto NO_NEW
- for %%1 in (*.lnk) do PLINK86 @%%1
- goto QUIT
- :NO_NEW
- echo There were no .PRG or .CLP files needing to be compiled.
- goto QUIT
- :NO_SOURCE
- echo There are no .PRG or .CLP file in this directory.
- goto QUIT
- :BAD_FILES
- echo There were one or more compilation errors. Examine
- echo CLP.TXT for details.
- goto QUIT
- :BAD_ARGS
- echo One or more arguments are run together.
- goto QUIT
- :WRONG_ARGS
- echo One or more arguments are unrecognized.
- goto QUIT
- :MISSING_FL
- echo One or more files contained in a .CLP file
- echo do not exist in the current directory.
- goto QUIT
- :DUPE_FL
- echo A program name was found in at least two .CLP
- echo files.
- goto QUIT
- :QUIT
- pause
- cls
-
-
-
-
-
-
-
- This software depends on the DOS ERRORLEVEL. Any
- software that intercepts or resets ERRORLEVEL will conflict
- with CLPMK20. At this time I am aware that FOXNET behaves in
- this manner. Consequently, you must NOT run FOXNET while
- using CLPMK20.
-
- This program scans the directory containing your .PRG and
- .CLP files and builds a simple binary tree for each type of
- file. I did this since a binary tree would allow me to
- efficiently sort file names as they were encountered during
- the directory scan, and search for file names as processing
- continued. I use recursive algorithms both to build and
- process the trees. If you have used Peter Nortons' DS (or any
- similar) utility to sort your directory by filename, my recursion
- algorithm will attempt to build a very unbalanced tree, and the
- program will blow up with a stack overflow error. To correct
- this problem, simply resort your directory on a combination
- of file date, file time, and file size. The files will then
- be unordered by name, and CLPMK20 should work fine (within
- the limits of a 9k stack).
-
- I have tested CLPMK20 on a machine with 590K free ram, 275
- .PRG and 36 .CLP files with no problems. CLPMK20 allocates
- memory dynamically for each .PRG and .CLP file it encounters
- during the directory scan (approx. 35 bytes for each file),
- so you may run into problems with a combination of greater
- numbers of .PRG and .CLP files and less free ram.
-
- If anyone discovers any other problems, please mail me a
- description of the problem at the listed P.O. box.
-
- Trademarks
-
- Clipper is a trademark of Nantucket Corp.
-
- CLPMK20.EXE
-
-
- INVOICE
-
- Make checks payable to:
-
- Bill Tansill Date: / /
- P.O. Box 3196
- Falls Church, Va. 22043
-
-
-
- Name, address, phone (Please type or print):
-
-
-
-
-
-
- Product Quantity Price Each Total
-
- CLPMK20 License Fee ________ @ $15.00 _______
-
-
- Total: _______
-
-